#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
int f_count(int x)
{	
	if (x <= 1)
		return 1;
	else
		return x * f_count(x-1);
}

int main()
{
	int i = 0;
	scanf("%d", &i);
	int ret = f_count(i);
	
	printf("%d", ret);

	return 0;
}












